home *** CD-ROM | disk | FTP | other *** search
/ Mac Mania 2 / MacMania 2.toast / Demo's / Music⁄Sounds / BeepSay 1.0.1 / makefile < prev    next >
Encoding:
Makefile  |  1993-06-22  |  6.5 KB  |  260 lines  |  [TEXT/MPS ]

  1. ##*****************************************************************************
  2. ##
  3. ##  Folder Name:    BeepSay
  4. ##     File Name:    Makefile
  5. ##
  6. ##   Copyright:        © 1993 Siren Enterprises, all rights reserved.
  7. ##
  8. ##   Description:    make rules for BeepSay
  9. ##
  10. ##*****************************************************************************
  11. ##                       A U T H O R   I D E N T I T Y
  12. ##*****************************************************************************
  13. ##
  14. ##    Initials    Name
  15. ##    --------    -----------------------------------------------
  16. ##    KW            Ken Wieschhoff
  17. ##
  18. ##*****************************************************************************
  19. ##                      R E V I S I O N   H I S T O R Y
  20. ##*****************************************************************************
  21. ##
  22. ##      Date        Time    Author    Description
  23. ##    --------    -----    ------    ---------------------------------------------
  24. ##    06/22/93    15:30    kw        1+ Update dependencies
  25. ##    12/13/91    2:33    KW        Original version 
  26. ##
  27. ##
  28. ##
  29.  
  30. ##*****************************************************************************
  31. ##                   C O M M O N  V A R S  &  R U L E S
  32. ##*****************************************************************************
  33. #
  34. #    Handy definitions
  35. TheTarget                    =        "BeepSay"
  36.  
  37. TargetObjects                =        :Objects:
  38.  
  39.  
  40. #
  41. #    Environment switches
  42. #
  43.  
  44. #    Symbols are useful for debugging
  45. SymFlag                        =        Full
  46.  
  47. #    Rebuilds the world if this file is modified (for major mods)
  48. #TheMakeFile                    =        MakeFile
  49. TheMakeFile                    =
  50.  
  51.  
  52. CSwitches                     =         -mbg {SymFlag}                                ∂
  53.                                     -sym {SymFlag}                                ∂
  54.                                     -b -r
  55.  
  56. PascalSwitches                =         -mbg {SymFlag}                                ∂
  57.                                     -sym {SymFlag}                                ∂
  58.                                     -r                                            
  59.  
  60. AssemblerSwitches            =        -sym {SymFlag} 
  61.  
  62. #     Can't use SADE for a CDEV/INIT, so don't create .SYM files
  63. ## KHW.  But we CAN use Jasik's.  Create the .SYM
  64. LinkSwitches            =         -t rsrc -c RSED -sym {SymFlag} -mf 
  65.  
  66. RezSwitches                        =    -s {TargetObjects}
  67.  
  68.  
  69. #
  70. #    StandardLibraries definition
  71. #
  72. StandardLibraries                =    "{Libraries}RunTime.o"        ∂
  73.                                     "{CLibraries}StdCLib.o"        ∂
  74.                                     "{PLibraries}PasLib.o"        ∂
  75.                                     "{Libraries}Interface.o"
  76.  
  77.  
  78. #
  79. #    Standard library
  80. #
  81. {TargetObjects}StandardLibrary        ƒ        {StandardLibraries}
  82.         echo "`date -s` -- Creating standard library"
  83.         Lib -d                        ∂
  84.             {StandardLibraries}         ∂
  85.             -o "{Targ}"
  86.         
  87. #
  88. #    Default rules
  89. #
  90. {TargetObjects}    ƒ    :
  91.  
  92. .c.o        ƒ    .c    {TheMakeFile}
  93.     echo    "`date -s` -- Compiling {Default}.c"
  94.     C         {CSwitches} {DepDir}{Default}.c -o {Targ}
  95.     
  96. .p.o        ƒ    .p    {TheMakeFile}
  97.     echo    "`date -s` -- Compiling {Default}.p"
  98.     Pascal    {PascalSwitches} {DepDir}{Default}.p -o {Targ}
  99.  
  100. .a.o        ƒ    .a    {TheMakeFile}
  101.     echo    "`date -s ` -- Assembling {Default}.a"
  102.     asm         {AssemblerSwitches} {DepDir}{Default}.a -o {Targ}
  103.  
  104. .rsrc        ƒ    .r
  105.     echo    "`date -s ` -- Rezzing {Default}.r"
  106.     Rez        {RezSwitches} -o {Targ} {DepDir}{default}.r    
  107.  
  108.  
  109. ##*****************************************************************************
  110. ##                        T A R G E T  R U L E S
  111. ##*****************************************************************************
  112.  
  113.  
  114. #
  115. #    TargetComponents definition
  116. #
  117. TargetComponents                =    {TargetObjects}StandardLibrary            ∂
  118.                                     {TargetObjects}INIT.rsrc                ∂
  119.                                     {TargetObjects}SYSB.rsrc                ∂
  120.                                     {TargetObjects}CDEV.rsrc                ∂
  121.                                     {TheTarget}.rsrc                        ∂
  122.                                     {TheTarget}.resource                    ∂
  123.                                     {TheTarget}.r                                
  124.  
  125. #
  126. #    Rez rules to build the complete Target
  127. #
  128. {TargetObjects}{TheTarget}        ƒ        {TheMakeFile}                     ∂
  129.                                         {TargetComponents}
  130.     echo "`date -s` -- Rezzing {Targ}"
  131.     delete -i {Targ}
  132.     Rez     {RezSwitches}                            ∂
  133.             BeepSay.r                                ∂
  134.             -c 'BPSA'                                ∂
  135.             -t 'cdev'                                ∂
  136.             -o {Targ}
  137.     SetFile    {Targ}                                    ∂
  138.             -a B                                    
  139.     echo "`date -s` -- Completed {Targ} build"
  140.  
  141.  
  142. #    COMMON dependencies 
  143. #
  144. "{TargetObjects}"Utilities.c.o        ƒ    Utilities.h
  145.  
  146. "{TargetObjects}"Preferences.c.o        ƒ    Preferences.h
  147.  
  148. #    CDEV code resource 
  149. #
  150. CDEVObjects =     {TargetObjects}CDEV.c.o                    ∂
  151.                 {TargetObjects}Preferences.c.o            ∂
  152.                 {TargetObjects}Utilities.c.o            ∂
  153.                 {TargetObjects}StandardLibrary            ∂
  154.  
  155.  
  156.  
  157. {TargetObjects}CDEV.rsrc             ƒƒ         {TheMakeFile}                     ∂
  158.                                             {CDEVObjects}                    ∂
  159.                                             CDEV.r
  160.     echo "`date -s` -- Linking {TheTarget} CDEV resource"
  161.     delete -i "{TargetObjects}CDEV.code"
  162.     delete -i "{TargetObjects}CDEV.code.dude"
  163.     delete -i "{TargetObjects}CDEV.rsrc"
  164.     Link     {LinkSwitches}        -br on                                        ∂
  165.             -rt cdev=-4064 -m MAIN                                              ∂
  166.             -c 'RSED' -t 'rsrc'                                                ∂
  167.             -sg "{TheTarget} CDEV"                                            ∂
  168.             {CDEVObjects}                                                    ∂
  169.             -o "{Targ}"                                                        ∂
  170.             -l >"{Targ}".map
  171.  
  172.  
  173. #    CDEV dependencies 
  174. #
  175. {TargetObjects}CDEV.c.o        ƒ    ∂
  176.     Utilities.h
  177.  
  178. #    INIT code resource 
  179. #
  180. INITObjects =     {TargetObjects}INIT.c.o                ∂
  181.                 {TargetObjects}Preferences.c.o        ∂
  182.                 {TargetObjects}Utilities.c.o        ∂
  183.                 {TargetObjects}ShowINIT.a.o            ∂
  184.                 {TargetObjects}SysBeep.a.o            ∂
  185.                 {TargetObjects}StandardLibrary
  186.  
  187. {TargetObjects}INIT.rsrc             ƒƒ         {TheMakeFile}                     ∂
  188.                                             {INITObjects}
  189.     echo "`date -s` -- Linking {TheTarget} INIT resource"
  190.     Link     {LinkSwitches}                                                    ∂
  191.             -rt INIT=-4064 -m entrypoint -ra =resSysHeap,resLocked             ∂
  192.             -sg "{TheTarget} INIT"                                            ∂
  193.             {INITObjects}                                                    ∂
  194.             -o "{Targ}"                                                        ∂
  195.             -l >"{Targ}".map
  196.  
  197. #    INIT dependencies 
  198. #
  199. {TargetObjects}INIT.c.o        ƒ            ∂
  200.     Preferences.h            ∂
  201.     Resident.h            ∂
  202.     Utilities.h            ∂
  203.     ShowINIT.h
  204.  
  205.  
  206.  
  207. #    SYSB (BeepSay Resident) code resource
  208. #
  209. SYSBObjects =     {TargetObjects}Resident.c.o            ∂
  210.                 {TargetObjects}Utilities.c.o        ∂
  211.                 {TargetObjects}SysBeep.a.o            ∂
  212.                 {TargetObjects}Preferences.c.o        ∂
  213.                 {TargetObjects}StandardLibrary
  214.  
  215.  
  216.  
  217.  
  218. # SingleSeg
  219. {TargetObjects}SYSB.rsrc             ƒƒ         {TheMakeFile}                     ∂
  220.                                             {SYSBObjects}                    ∂
  221.                                             SYSB.r
  222.     echo "`date -s` -- Linking {TheTarget} SYSB resource"
  223.     delete -i "{TargetObjects}SYSB.code"
  224.     delete -i "{TargetObjects}SYSB.code.dude"
  225.     delete -i "{TargetObjects}SYSB.rsrc"
  226.     Link     {LinkSwitches} -br on                                             ∂
  227.             -rt SYSB=1 -m MAIN -ra =resSysHeap,resLocked                     ∂
  228.             -c 'RSED' -t 'rsrc'                                                ∂
  229.             -sg "{TheTarget} SYSB"                                            ∂
  230.             {SYSBObjects}                                                    ∂
  231.             -o "{Targ}"                                                        ∂
  232.             -l >"{Targ}".map
  233.  
  234.  
  235. {TargetObjects}Resident.c.o        ƒ    ∂
  236.     Utilities.h                            ∂
  237.     Resident.h
  238.  
  239. {TargetObjects}Sayit            ƒƒ    Sayit.r
  240.     Rez Sayit.r -o Sayit -append
  241. {TargetObjects}Sayit            ƒƒ    Sayit.c.o
  242.     echo "`date -s` -- Linking {TheTarget} MPW Tool"
  243.     Link -sym {SymFlag} -w -c 'MPS ' -t MPST Sayit.c.o ∂
  244.         -sn STDIO=Main ∂
  245.         -sn INTENV=Main ∂
  246.         -sn %A5Init=Main ∂
  247.         "{Libraries}"Stubs.o ∂
  248.         "{CLibraries}"StdCLib.o ∂
  249.         "{Libraries}"Interface.o ∂
  250.         "{Libraries}"Runtime.o ∂
  251.         "{Libraries}"ToolLibs.o ∂
  252.         -o Sayit
  253.  
  254.